package com.originskyseed.platform.cms.service;

import java.util.List;
import java.util.Map;

import com.originskyseed.platform.cms.model.CmsSource;
import com.originskyseed.platform.core.base.BasePage;

/**
 * 内容来源Service接口类
 * 
 * @author LiangMingHui
 *
 */
public interface ICmsSourceService {

	/**
	 * deleteByPrimaryKey
	 * 
	 * @param id
	 * @return
	 * @throws Exception
	 */
	public int deleteByPrimaryKey(String id) throws Exception;

	/**
	 * deleteByPrimaryKeys
	 * 
	 * @param ids
	 * @return
	 * @throws Exception
	 */
	public int deleteByPrimaryKeys(List<String> ids) throws Exception;

	/**
	 * insert
	 * 
	 * @param record
	 * @return
	 * @throws Exception
	 */
	public int insert(CmsSource record) throws Exception;

	/**
	 * insertSelective
	 * 
	 * @param record
	 * @return
	 * @throws Exception
	 */
	public int insertSelective(CmsSource record) throws Exception;

	/**
	 * selectByPrimaryKey
	 * 
	 * @param id
	 * @return
	 * @throws Exception
	 */
	public CmsSource selectByPrimaryKey(String id) throws Exception;

	/**
	 * selectByNameCn
	 *
	 * @param params
	 * @return
	 * @throws Exception
	 */
	public CmsSource selectByNameCn(Map<String, Object> params) throws Exception;

	/**
	 * updateByPrimaryKeySelective
	 * 
	 * @param record
	 * @return
	 * @throws Exception
	 */
	public int updateByPrimaryKeySelective(CmsSource record) throws Exception;

	/**
	 * updateByPrimaryKey
	 * 
	 * @param record
	 * @return
	 * @throws Exception
	 */
	public int updateByPrimaryKey(CmsSource record) throws Exception;

	/**
	 * 分页查询内容列表
	 *
	 * @param params
	 * @param page
	 * @return
	 * @throws Exception
	 */
	public BasePage<CmsSource> selectListByPage(Map<String, Object> params, BasePage<CmsSource> page) throws Exception;

	/**
	 * 是否存在来源名称
	 * 
	 * @param cmsSource
	 * @return
	 * @throws Exception
	 */
	public Boolean existSourceNameCn(CmsSource cmsSource) throws Exception;

	/**
	 * 查询所有内容来源
	 * 
	 * @return
	 * @throws Exception
	 */
	public List<CmsSource> selectAll(Map<String, Object> params) throws Exception;

}
